<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>chef-server-ctl (executable) &mdash; chef-client Man Pages</title>
    
    <link rel="stylesheet" href="_static/guide.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    './',
        VERSION:     '',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>


  </head>
  <body>
<div style="background-color: #212c35; text-align: left; padding: 0px 0px 0px 0px">
<a href="http://docs.getchef.com/"><img src="_static/chef_html_logo.png" border="0" alt="Chef"/></a>
</div>


  

    <div class="document">
      <div class="documentwrapper">

          <div class="body">
            
  <div class="section" id="chef-server-ctl-executable">
<h1>chef-server-ctl (executable)<a class="headerlink" href="#chef-server-ctl-executable" title="Permalink to this headline">¶</a></h1>
<p>The Chef server includes a command-line utility named chef-server-ctl. This command-line tool is used to start and stop individual services, reconfigure the Chef server, run chef-pedant, and then tail Chef server log files.</p>
<div class="section" id="backup-recover">
<h2>backup-recover<a class="headerlink" href="#backup-recover" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">backup-recover</span></tt> subcommand is used to force the Chef server to attempt to become the backup server. This is the opposite of the <tt class="docutils literal"><span class="pre">master-recover</span></tt> subcommand.</p>
<div class="admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">If this command is run on both back-end servers, it will put the back-end cluster into a state where no server holds the DRBD resource.</p>
</div>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl backup-recover
</pre></div>
</div>
</div>
<div class="section" id="cleanse">
<h2>cleanse<a class="headerlink" href="#cleanse" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">cleanse</span></tt> subcommand is used to re-set the Chef server to the state it was in before the first time the <tt class="docutils literal"><span class="pre">reconfigure</span></tt> subcommand is run to destroy all data, configuration files, and logs.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl cleanse
</pre></div>
</div>
</div>
<div class="section" id="gather-logs">
<h2>gather-logs<a class="headerlink" href="#gather-logs" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">gather-logs</span></tt> subcommand is used to gather the Chef server log files into a tarball that contains all of the important log files and system information.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl gather-logs
</pre></div>
</div>
</div>
<div class="section" id="ha-status">
<h2>ha-status<a class="headerlink" href="#ha-status" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">ha-status</span></tt> subcommand is used to check the status for services running in a High Availability topology. This command will verify the following:</p>
<blockquote>
<div><ul class="simple">
<li>The Keepalived daemon is enabled in the config</li>
<li>The DRBD process is enabled in the config</li>
<li>The underlying block device or logical volume for DRBD has been created and configured</li>
<li>The DRBD device exists</li>
<li>The current state of the server is <tt class="docutils literal"><span class="pre">master</span></tt> or <tt class="docutils literal"><span class="pre">backup</span></tt>; any migration processes have completed</li>
<li>The failover virtual IP address is correctly attached to only the <tt class="docutils literal"><span class="pre">master</span></tt> node</li>
<li>The DRBD state is correct based on the state of the server being <tt class="docutils literal"><span class="pre">master</span></tt> or <tt class="docutils literal"><span class="pre">backup</span></tt></li>
<li>The DRBD mount point is correctly mounted to only the <tt class="docutils literal"><span class="pre">master</span></tt> node</li>
<li>The DRBD replication IP addresses are pingable</li>
<li>The <tt class="docutils literal"><span class="pre">runit</span></tt> status of the services are correct (up or down) based on the <tt class="docutils literal"><span class="pre">master</span></tt> or <tt class="docutils literal"><span class="pre">backup</span></tt> state of the server</li>
</ul>
</div></blockquote>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl ha-status
</pre></div>
</div>
<p>If this command runs successfully, it will return the following:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span><span class="o">[</span>OK<span class="o">]</span> all checks passed.
</pre></div>
</div>
<p>Otherwise it will print out a list of errors, similar to the following:</p>
<div class="highlight-bash"><div class="highlight"><pre>...
<span class="o">[</span>OK<span class="o">]</span> nginx is running correctly, and I am master.
<span class="o">[</span>ERROR<span class="o">]</span> redis_lb is not running.
<span class="o">[</span>OK<span class="o">]</span> opscode-erchef is running correctly, and I am master.
...
<span class="o">[</span>ERROR<span class="o">]</span> ERRORS WERE DETECTED.
</pre></div>
</div>
<p>For example:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="o">[</span>OK<span class="o">]</span> keepalived HA services enabled
<span class="o">[</span>OK<span class="o">]</span> DRBD disk replication enabled
<span class="o">[</span>OK<span class="o">]</span> DRBD partition /dev/opscode/drbd found
<span class="o">[</span>OK<span class="o">]</span> DRBD device /dev/drbd0 found
<span class="o">[</span>OK<span class="o">]</span> cluster <span class="nv">status</span> <span class="o">=</span> master
<span class="o">[</span>OK<span class="o">]</span> found VIP IP address and I am master
<span class="o">[</span>OK<span class="o">]</span> found VRRP communications interface eth1
<span class="o">[</span>OK<span class="o">]</span> my DRBD status is Connected/Primary/UpToDate and I am master
<span class="o">[</span>OK<span class="o">]</span> my DRBD partition is mounted and I am master
<span class="o">[</span>OK<span class="o">]</span> DRBD primary IP address pings
<span class="o">[</span>OK<span class="o">]</span> DRBD secondary IP address pings
...
<span class="o">[</span>OK<span class="o">]</span> all checks passed.
</pre></div>
</div>
</div>
<div class="section" id="help">
<h2>help<a class="headerlink" href="#help" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">help</span></tt> subcommand is used to print a list of all available chef-server-ctl commands.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl <span class="nb">help</span>
</pre></div>
</div>
</div>
<div class="section" id="install">
<h2>install<a class="headerlink" href="#install" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">install</span></tt> subcommand is used to install premium features of the Chef server: Chef management console, Chef analytics, chef-client run reporting, high availability configurations, Chef push jobs, and Chef server replication.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl install name_of_premium_feature <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_premium_feature</span></tt> represents the command line value associated with the premium feature:</p>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">--path</span> <span class="pre">PATH</span></tt></dt>
<dd>Use to specify the location of a package. This option is not required when packages are downloaded from <a class="reference external" href="https://packagecloud.io/">https://packagecloud.io/</a>.</dd>
</dl>
<div class="section" id="use-downloads">
<h3>Use Downloads<a class="headerlink" href="#use-downloads" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">install</span></tt> subcommand downloads packages from <a class="reference external" href="https://packagecloud.io/">https://packagecloud.io/</a> by default. For systems that are not behind a firewall (and have connectivity to <a class="reference external" href="https://packagecloud.io/">https://packagecloud.io/</a>), these packages can be installed as described below.</p>
<table border="1" class="docutils">
<colgroup>
<col width="20%" />
<col width="80%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Feature</th>
<th class="head">Command</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td>Chef Manage</td>
<td><p class="first">Use Chef management console to manage data bags, attributes, run-lists, roles, environments, and cookbooks from a web user interface.</p>
<p>(Front end machines only.) Run:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl install opscode-manage
</pre></div>
</div>
<p>then:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ opscode-manage-ctl reconfigure
</pre></div>
</div>
<p>and then:</p>
<div class="last highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl reconfigure
</pre></div>
</div>
</td>
</tr>
<tr class="row-odd"><td>Chef Push Jobs</td>
<td><p class="first">Use Chef push jobs to run jobs&#8212;an action or a command to be executed&#8212;against nodes independently of a chef-client run.</p>
<p>Run:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl install opscode-push-jobs-server
</pre></div>
</div>
<p>then:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ opscode-push-jobs-server-ctl reconfigure
</pre></div>
</div>
<p>and then:</p>
<div class="last highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl reconfigure
</pre></div>
</div>
</td>
</tr>
<tr class="row-even"><td>Chef Replication</td>
<td><p class="first">Use Chef replication to asynchronously distribute cookbook, environment, role, and data bag data from a single, primary Chef server to one (or more) replicas of that Chef server.</p>
<p>Run:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl install chef-sync
</pre></div>
</div>
<p>and then:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ chef-sync-ctl reconfigure
</pre></div>
</div>
<p>and then:</p>
<div class="last highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl reconfigure
</pre></div>
</div>
</td>
</tr>
<tr class="row-odd"><td>Reporting</td>
<td><p class="first">Use Chef reporting to keep track of what happens during every chef-client runs across all of the infrastructure being managed by Chef. Run Chef reporting with Chef management console to view reports from a web user interface.</p>
<p>(Front end machines only.) Run:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl install opscode-reporting
</pre></div>
</div>
<p>then:</p>
<div class="highlight-ruby"><div class="highlight"><pre>$ opscode-reporting-ctl reconfigure
</pre></div>
</div>
<p>and then:</p>
<div class="last highlight-ruby"><div class="highlight"><pre>$ chef-server-ctl reconfigure
</pre></div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="use-local-packages">
<h3>Use Local Packages<a class="headerlink" href="#use-local-packages" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">install</span></tt> subcommand downloads packages from <a class="reference external" href="https://packagecloud.io/">https://packagecloud.io/</a> by default. For systems that are behind a firewall (and do not have connectivity to <a class="reference external" href="https://packagecloud.io/">https://packagecloud.io/</a>), these packages can be installed manually. First download the package that is appropriate for the platform and save it to a local path. Then run the <tt class="docutils literal"><span class="pre">install</span></tt> command using the <tt class="docutils literal"><span class="pre">--path</span></tt> option to specify the location for the package:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl install NAME_OF_PACKAGE --path /path/to/package
</pre></div>
</div>
<p>For example:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl install opscode-manage-1.6.2-1.el6.x86_64 --path /home/vagrant
</pre></div>
</div>
</div>
</div>
<div class="section" id="master-recover">
<h2>master-recover<a class="headerlink" href="#master-recover" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">master-recover</span></tt> subcommand is used to force the Chef server to attempt to become the master server. This command is typically run in tandem with the <tt class="docutils literal"><span class="pre">backup-recover</span></tt> subcommand on the back-end peer, unless the back-end peer is no longer available.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl master-recover
</pre></div>
</div>
</div>
<div class="section" id="org-create">
<h2>org-create<a class="headerlink" href="#org-create" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-create</span></tt> subcommand is used to create an organization. (The validation key for the organization is returned to <tt class="docutils literal"><span class="pre">STDOUT</span></tt> when creating an organization using this command.)</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-create ORG_NAME ORG_FULL_NAME <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-a</span> <span class="pre">USER_NAME</span></tt>, <tt class="docutils literal"><span class="pre">--association_user</span> <span class="pre">USER_NAME</span></tt></dt>
<dd>Use to associate a user with an organization and add them to the <tt class="docutils literal"><span class="pre">admins</span></tt> and <tt class="docutils literal"><span class="pre">billing_admins</span></tt> security groups.</dd>
<dt><tt class="docutils literal"><span class="pre">-f</span> <span class="pre">FILE_NAME</span></tt>, <tt class="docutils literal"><span class="pre">--filename</span> <span class="pre">FILE_NAME</span></tt></dt>
<dd>Use to write the private key to a file instead of <tt class="docutils literal"><span class="pre">STDOUT</span></tt>.</dd>
</dl>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-create prod Production
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-create staging Staging -a chef-admin
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-create dev Development -f /tmp/id-dev.key
</pre></div>
</div>
</div>
<div class="section" id="org-delete">
<h2>org-delete<a class="headerlink" href="#org-delete" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-delete</span></tt> subcommand is used to delete an organization.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-delete ORG_NAME
</pre></div>
</div>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-delete infra-testing-20140909
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-delete pedant-testing-org
</pre></div>
</div>
</div>
<div class="section" id="org-list">
<h2>org-list<a class="headerlink" href="#org-list" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-list</span></tt> subcommand is used to list all of the organizations currently present on the Chef server.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-list <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-a</span></tt>, <tt class="docutils literal"><span class="pre">--all-orgs</span></tt></dt>
<dd>Use to show all organizations.</dd>
<dt><tt class="docutils literal"><span class="pre">-w</span></tt>, <tt class="docutils literal"><span class="pre">--with-uri</span></tt></dt>
<dd>Use to show the corresponding URIs.</dd>
</dl>
</div>
<div class="section" id="org-show">
<h2>org-show<a class="headerlink" href="#org-show" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-show</span></tt> subcommand is used to show the details for an organization.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-show ORG_NAME
</pre></div>
</div>
</div>
<div class="section" id="org-user-add">
<h2>org-user-add<a class="headerlink" href="#org-user-add" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-user-add</span></tt> subcommand is used to add a user to an organization.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-add ORG_NAME USER_NAME <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">--admin</span></tt></dt>
<dd>Use to add the user to the <tt class="docutils literal"><span class="pre">admins</span></tt> group.</dd>
</dl>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-add prod john_smith
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-add preprod testmaster
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-add dev grantmc --admin
</pre></div>
</div>
</div>
<div class="section" id="org-user-remove">
<h2>org-user-remove<a class="headerlink" href="#org-user-remove" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">org-user-remove</span></tt> subcommand is used to remove a user from an organization.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-remove ORG_NAME USER_NAME
</pre></div>
</div>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-remove prod john_smith
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl org-user-remove prod testmaster
</pre></div>
</div>
</div>
<div class="section" id="password">
<h2>password<a class="headerlink" href="#password" title="Permalink to this headline">¶</a></h2>
<div class="admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">This subcommand is currently disabled.</p>
</div>
</div>
<div class="section" id="reconfigure">
<h2>reconfigure<a class="headerlink" href="#reconfigure" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">reconfigure</span></tt> subcommand is used when changes are made to the private-chef.rb file to reconfigure the server. When changes are made to the private-chef.rb file, they will not be applied to the Chef server configuration until after this command is run. This subcommand will also restart any services for which the <tt class="docutils literal"><span class="pre">service_name['enabled']</span></tt> setting is set to <tt class="docutils literal"><span class="pre">true</span></tt>.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl reconfigure
</pre></div>
</div>
</div>
<div class="section" id="show-config">
<h2>show-config<a class="headerlink" href="#show-config" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">show-config</span></tt> subcommand is used to view the configuration that will be generated by the <tt class="docutils literal"><span class="pre">reconfigure</span></tt> subcommand. This command is most useful in the early stages of a deployment to ensure that everything is built properly prior to installation.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl show-config
</pre></div>
</div>
</div>
<div class="section" id="uninstall">
<h2>uninstall<a class="headerlink" href="#uninstall" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">uninstall</span></tt> subcommand is used to remove the Chef server application, but without removing any of the data. This subcommand will shut down all services (including the <tt class="docutils literal"><span class="pre">runit</span></tt> process supervisor).</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl uninstall
</pre></div>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">To revert the <tt class="docutils literal"><span class="pre">uninstall</span></tt> subcommand, run the <tt class="docutils literal"><span class="pre">reconfigure</span></tt> subcommand (because the <tt class="docutils literal"><span class="pre">start</span></tt> subcommand is disabled by the <tt class="docutils literal"><span class="pre">uninstall</span></tt> command).</p>
</div>
</div>
<div class="section" id="upgrade">
<h2>upgrade<a class="headerlink" href="#upgrade" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">upgrade</span></tt> subcommand is used to upgrade the Chef server.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl upgrade <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Options for the <tt class="docutils literal"><span class="pre">upgrade</span></tt> subcommand may only be used when upgrading from Open Source Chef 11 to Chef server 12.</p>
</div>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-d</span> <span class="pre">DIRECTORY</span></tt>, <tt class="docutils literal"><span class="pre">--chef11-data-dir</span> <span class="pre">DIRECTORY</span></tt></dt>
<dd>The directory in which Open Source Chef 11 data is located. Default value: a temporary directory.</dd>
<dt><tt class="docutils literal"><span class="pre">-e</span> <span class="pre">DIRECTORY</span></tt>, <tt class="docutils literal"><span class="pre">--chef12-data-dir</span> <span class="pre">DIRECTORY</span></tt></dt>
<dd>The directory in which Chef server 12 data is located. Default value: a temporary directory.</dd>
<dt><tt class="docutils literal"><span class="pre">-f</span> <span class="pre">FULL_NAME</span></tt>, <tt class="docutils literal"><span class="pre">--full-org-name</span> <span class="pre">FULL_NAME</span></tt></dt>
<dd>The full name of the Chef server organization. A full organization name must begin with a non-white space character and must be between 1 and 1023 characters. For example: <tt class="docutils literal"><span class="pre">Chef</span> <span class="pre">Software,</span> <span class="pre">Inc.</span></tt>. If this option is not specified, the <tt class="docutils literal"><span class="pre">upgrade</span></tt> command will prompt for it.</dd>
<dt><tt class="docutils literal"><span class="pre">-h</span></tt>, <tt class="docutils literal"><span class="pre">--help</span></tt></dt>
<dd>Use to show help for the <tt class="docutils literal"><span class="pre">chef-server-ctl</span> <span class="pre">upgrade</span></tt> subcommand.</dd>
<dt><tt class="docutils literal"><span class="pre">-k</span> <span class="pre">KEY</span></tt>, <tt class="docutils literal"><span class="pre">--key</span> <span class="pre">KEY</span></tt></dt>
<dd>All users are assigned a public key. Use to write the public key to a file. Default value: <tt class="docutils literal"><span class="pre">/etc/chef-server/admin.pem</span></tt>.</dd>
<dt><tt class="docutils literal"><span class="pre">-o</span> <span class="pre">ORG_NAME</span></tt>, <tt class="docutils literal"><span class="pre">--org-name</span> <span class="pre">ORG_NAME</span></tt></dt>
<dd>The name of the Chef server organization. An organization name must begin with a lower-case letter or digit, may only contain lower-case letters, digits, hyphens, and underscores, and must be between 1 and 255 characters. For example: <tt class="docutils literal"><span class="pre">chef</span></tt>. If this option is not specified, the <tt class="docutils literal"><span class="pre">upgrade</span></tt> command will prompt for it.</dd>
<dt><tt class="docutils literal"><span class="pre">-s</span> <span class="pre">URL</span></tt>, <tt class="docutils literal"><span class="pre">--chef11-server-url</span> <span class="pre">URL</span></tt></dt>
<dd>The URL for the Open Source Chef or Enterprise Chef server, version 11. Default value: <tt class="docutils literal"><span class="pre">https://localhost</span></tt>.</dd>
<dt><tt class="docutils literal"><span class="pre">-t</span> <span class="pre">NUMBER</span></tt>, <tt class="docutils literal"><span class="pre">--upload-threads</span> <span class="pre">NUMBER</span></tt></dt>
<dd>The number of threads to use when migrating cookbooks. Default value: <tt class="docutils literal"><span class="pre">10</span></tt>.</dd>
<dt><tt class="docutils literal"><span class="pre">-u</span> <span class="pre">USER</span></tt>, <tt class="docutils literal"><span class="pre">--user</span></tt></dt>
<dd>Use to create a client as an admin client. This is required for any user to access Open Source Chef as an administrator.</dd>
<dt><tt class="docutils literal"><span class="pre">-x</span> <span class="pre">URL</span></tt>, <tt class="docutils literal"><span class="pre">--chef12-server-url</span> <span class="pre">URL</span></tt></dt>
<dd>The URL for the Chef server, version 12. Default value: <tt class="docutils literal"><span class="pre">https://localhost</span></tt>.</dd>
<dt><tt class="docutils literal"><span class="pre">-y</span></tt>, <tt class="docutils literal"><span class="pre">--yes</span></tt></dt>
<dd>Use to skip confirmation prompts during the upgrade process.</dd>
</dl>
</div>
<div class="section" id="user-create">
<h2>user-create<a class="headerlink" href="#user-create" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">user-create</span></tt> subcommand is used to create a user.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-create USER_NAME FIRST_NAME <span class="o">[</span>MIDDLE_NAME<span class="o">]</span> LAST_NAME EMAIL PASSWORD <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-f</span> <span class="pre">FILE_NAME</span></tt>, <tt class="docutils literal"><span class="pre">--filename</span> <span class="pre">FILE_NAME</span></tt></dt>
<dd>Use to write the private key to a file instead of <tt class="docutils literal"><span class="pre">STDOUT</span></tt>.</dd>
</dl>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-create john_smith John Smith john_smith@example.com insecure-passord
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-create jane_doe Jane Doe jane_doe@example.com PaSSword -f /tmp/jane_doe.key
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-create waldendude Henry David Thoreau waldendude@example.com excursions
</pre></div>
</div>
</div>
<div class="section" id="user-delete">
<h2>user-delete<a class="headerlink" href="#user-delete" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">user-delete</span></tt> subcommand is used to delete a user.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-delete USER_NAME
</pre></div>
</div>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-delete john_smith
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-delete jane_doe
</pre></div>
</div>
</div>
<div class="section" id="user-edit">
<h2>user-edit<a class="headerlink" href="#user-edit" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">user-edit</span></tt> subcommand is used to edit the details for a user. The data will be made available in the $EDITOR for editing.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-edit USER_NAME
</pre></div>
</div>
<p><strong>Examples</strong></p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-edit john_smith
</pre></div>
</div>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-edit jane_doe
</pre></div>
</div>
</div>
<div class="section" id="user-list">
<h2>user-list<a class="headerlink" href="#user-list" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">user-list</span></tt> subcommand is used to view a list of users.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-list <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-w</span></tt>, <tt class="docutils literal"><span class="pre">--with-uri</span></tt></dt>
<dd>Use to show the corresponding URIs.</dd>
</dl>
</div>
<div class="section" id="user-show">
<h2>user-show<a class="headerlink" href="#user-show" title="Permalink to this headline">¶</a></h2>
<p>The <tt class="docutils literal"><span class="pre">user-show</span></tt> subcommand is used to show the details for a user.</p>
<p><strong>Syntax</strong></p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl user-show USER_NAME <span class="o">(</span>options<span class="o">)</span>
</pre></div>
</div>
<p><strong>Options</strong></p>
<p>This subcommand has the following options:</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">-l</span></tt>, <tt class="docutils literal"><span class="pre">--with-orgs</span></tt></dt>
<dd>Use to show the corresponding organizations.</dd>
</dl>
</div>
<div class="section" id="service-subcommands">
<h2>Service Subcommands<a class="headerlink" href="#service-subcommands" title="Permalink to this headline">¶</a></h2>
<p>The Chef server has a built in process supervisor, which ensures that all of the required services are in the appropriate state at any given time. The supervisor starts two processes per service.</p>
<div class="section" id="hup">
<h3>hup<a class="headerlink" href="#hup" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">hup</span></tt> subcommand is used to send a <tt class="docutils literal"><span class="pre">SIGHUP</span></tt> to all services. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl hup name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
<div class="section" id="int">
<h3>int<a class="headerlink" href="#int" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">int</span></tt> subcommand is used to send a <tt class="docutils literal"><span class="pre">SIGINT</span></tt> to all services. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl int name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
<div class="section" id="kill">
<h3>kill<a class="headerlink" href="#kill" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">kill</span></tt> subcommand is used to send a <tt class="docutils literal"><span class="pre">SIGKILL</span></tt> to all services. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl <span class="nb">kill </span>name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
<div class="section" id="once">
<h3>once<a class="headerlink" href="#once" title="Permalink to this headline">¶</a></h3>
<p>The supervisor for the Chef server is configured to restart any service that fails, unless that service has been asked to change its state. The <tt class="docutils literal"><span class="pre">once</span></tt> subcommand is used to tell the supervisor to not attempt to restart any service that fails.</p>
<p>This command is useful when troubleshooting configuration errors that prevent a service from starting. Run the <tt class="docutils literal"><span class="pre">once</span></tt> subcommand followed by the <tt class="docutils literal"><span class="pre">status</span></tt> subcommand to look for services in a down state and/or to identify which services are in trouble. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl once name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
<div class="section" id="restart">
<h3>restart<a class="headerlink" href="#restart" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">restart</span></tt> subcommand is used to restart all services enabled on the Chef server or to restart an individual service by specifying the name of that service in the command.</p>
<div class="admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">When running the Chef server in a high availability configuration, restarting all services may trigger failover.</p>
</div>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl restart name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand. When a service is successfully restarted the output should be similar to:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>ok: run: service_name: <span class="o">(</span>pid 12345<span class="o">)</span> 1s
</pre></div>
</div>
</div>
<div class="section" id="service-list">
<h3>service-list<a class="headerlink" href="#service-list" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand is used to display a list of all available services. A service that is enabled is labeled with an asterisk (*).</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl service-list
</pre></div>
</div>
</div>
<div class="section" id="start">
<h3>start<a class="headerlink" href="#start" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">start</span></tt> subcommand is used to start all services that are enabled in the Chef server. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl start name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand. When a service is successfully started the output should be similar to:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>ok: run: service_name: <span class="o">(</span>pid 12345<span class="o">)</span> 1s
</pre></div>
</div>
<p>The supervisor for the Chef server is configured to wait seven seconds for a service to respond to a command from the supervisor. If you see output that references a timeout, it means that a signal has been sent to the process, but that the process has yet to actually comply. In general, processes that have timed out are not a big concern, unless they are failing to respond to the signals at all. If a process is not responding, use a command like the <tt class="docutils literal"><span class="pre">kill</span></tt> subcommand to stop the process, investigate the cause (if required), and then use the <tt class="docutils literal"><span class="pre">start</span></tt> subcommand to re-enable it.</p>
</div>
<div class="section" id="status">
<h3>status<a class="headerlink" href="#status" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">status</span></tt> subcommand is used to show the status of all services available to the Chef server. The results will vary based on the configuration of a given server. This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl status
</pre></div>
</div>
<p>and will return the status for all services. Status can be returned for individual services by specifying the name of the service as part of the command:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl status name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
<p>When service status is requested, the output should be similar to:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>run: service_name: <span class="o">(</span>pid 12345<span class="o">)</span> 12345s; run: log: <span class="o">(</span>pid 1234<span class="o">)</span> 67890s
</pre></div>
</div>
<p>where</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">run:</span></tt> is the state of the service (<tt class="docutils literal"><span class="pre">run:</span></tt> or <tt class="docutils literal"><span class="pre">down:</span></tt>)</li>
<li><tt class="docutils literal"><span class="pre">service_name:</span></tt> is the name of the service for which status is returned</li>
<li><tt class="docutils literal"><span class="pre">(pid</span> <span class="pre">12345)</span></tt> is the process identifier</li>
<li><tt class="docutils literal"><span class="pre">12345s</span></tt> is the uptime of the service, in seconds</li>
</ul>
<p>For example:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>down: opscode-erchef: <span class="o">(</span>pid 35546<span class="o">)</span> 10s
</pre></div>
</div>
<p>By default, runit will restart services automatically when the services fail. Therefore, runit may report the status of a service as <tt class="docutils literal"><span class="pre">run:</span></tt> even when there is an issue with that service. When investigating why a particular service is not running as it should be, look for the services with the shortest uptimes. For example, the list below indicates that the <strong>opscode-erchef</strong> should be investigated further:</p>
<div class="highlight-bash"><div class="highlight"><pre>run: oc-id
run: opscode-chef: <span class="o">(</span>pid 4327<span class="o">)</span> 13671s; run: log: <span class="o">(</span>pid 4326<span class="o">)</span> 13671s
run: opscode-erchef: <span class="o">(</span>pid 5383<span class="o">)</span> 5s; run: log: <span class="o">(</span>pid 4382<span class="o">)</span> 13669s
run: opscode-expander: <span class="o">(</span>pid 4078<span class="o">)</span> 13694s; run: log: <span class="o">(</span>pid 4077<span class="o">)</span> 13694s
run: opscode-expander-reindexer: <span class="o">(</span>pid 4130<span class="o">)</span> 13692s; run: log: <span class="o">(</span>pid 4114<span class="o">)</span> 13692s
</pre></div>
</div>
<div class="section" id="high-availability">
<h4>High Availability<a class="headerlink" href="#high-availability" title="Permalink to this headline">¶</a></h4>
<p>On back-end servers in a High Availability topology, Keepalived is used by the clustering service to determine whether a service should be running. If the <tt class="docutils literal"><span class="pre">status</span></tt> subcommand is run against any of these nodes, a few things change:</p>
<ul class="simple">
<li>On the back-end node that is currently the backup server, it is normal to see only one running process: Keepalived</li>
<li>On the back-end node that is currently the master server, it is normal to see all services running. It is also normal to see some services in a down state if the server, on reboot, did not attempt to start the services because Keepalived determines which services are restarted based on the state of the cluster</li>
</ul>
<p>A sample status line for a service that is running on the master server in a High Availability topology:</p>
<div class="highlight-bash"><div class="highlight"><pre>run: opscode-solr: <span class="o">(</span>pid 25341<span class="o">)</span> 239s, normally down; run: log: <span class="o">(</span>pid 5700<span class="o">)</span> 145308s
</pre></div>
</div>
</div>
<div class="section" id="log-files">
<h4>Log Files<a class="headerlink" href="#log-files" title="Permalink to this headline">¶</a></h4>
<p>A typical status line for a service that is running any of the Chef server front-end services is similar to the following:</p>
<div class="highlight-bash"><div class="highlight"><pre>run: name_of_service: <span class="o">(</span>pid 1486<span class="o">)</span> 7819s; run: log: <span class="o">(</span>pid 1485<span class="o">)</span> 7819s
</pre></div>
</div>
<p>where:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">run</span></tt> describes the state in which the supervisor attempts to keep processes. This state is either <tt class="docutils literal"><span class="pre">run</span></tt> or <tt class="docutils literal"><span class="pre">down</span></tt>. If a service is in a <tt class="docutils literal"><span class="pre">down</span></tt> state, it should be stopped</li>
<li><tt class="docutils literal"><span class="pre">name_of_service</span></tt> is the service name, for example: <tt class="docutils literal"><span class="pre">opscode-solr4</span></tt></li>
<li><tt class="docutils literal"><span class="pre">(pid</span> <span class="pre">1486)</span> <span class="pre">7819s;</span></tt> is the process identifier followed by the amount of time (in seconds) the service has been running</li>
<li><tt class="docutils literal"><span class="pre">run:</span> <span class="pre">log:</span> <span class="pre">(pid</span> <span class="pre">1485)</span> <span class="pre">7819s</span></tt> is the log process. It is typical for a log process to have a longer run time than a service; this is because the supervisor does not need to restart the log process in order to connect the supervised process</li>
</ul>
<p>If the service is down, the status line will appear similar to the following:</p>
<div class="highlight-bash"><div class="highlight"><pre>down: opscode-solr4: 3s, normally up; run: log: <span class="o">(</span>pid 1485<span class="o">)</span> 8526s
</pre></div>
</div>
<p>where</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">down</span></tt> indicates that the service is in a down state</li>
<li><tt class="docutils literal"><span class="pre">3s,</span> <span class="pre">normally</span> <span class="pre">up;</span></tt> indicates that the service is normally in a run state and that the supervisor would attempt to restart this service after a reboot</li>
</ul>
</div>
</div>
<div class="section" id="stop">
<h3>stop<a class="headerlink" href="#stop" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">stop</span></tt> subcommand is used to stop all services enabled on the Chef server. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl stop name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand. When a service is successfully stopped the output should be similar to:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>ok: diwb: service_name: 0s, normally up
</pre></div>
</div>
<p>For example:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl stop
</pre></div>
</div>
<p>will return something similar to:</p>
<div class="highlight-bash"><div class="highlight"><pre>ok: down: nginx: 393s, normally up
ok: down: opscode-chef: 391s, normally up
ok: down: opscode-erchef: 391s, normally up
ok: down: opscode-expander: 390s, normally up
ok: down: opscode-expander-reindexer: 389s, normally up
ok: down: opscode-solr4: 389s, normally up
ok: down: postgresql: 388s, normally up
ok: down: rabbitmq: 388s, normally up
ok: down: redis_lb: 387s, normally up
</pre></div>
</div>
</div>
<div class="section" id="tail">
<h3>tail<a class="headerlink" href="#tail" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">tail</span></tt> subcommand is used to follow all of the Chef server logs for all services. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl tail name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
<div class="section" id="term">
<h3>term<a class="headerlink" href="#term" title="Permalink to this headline">¶</a></h3>
<p>The <tt class="docutils literal"><span class="pre">term</span></tt> subcommand is used to send a <tt class="docutils literal"><span class="pre">SIGTERM</span></tt> to all services. This command can also be run for an individual service by specifying the name of the service in the command.</p>
<p>This subcommand has the following syntax:</p>
<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>chef-server-ctl term name_of_service
</pre></div>
</div>
<p>where <tt class="docutils literal"><span class="pre">name_of_service</span></tt> represents the name of any service that is listed after running the <tt class="docutils literal"><span class="pre">service-list</span></tt> subcommand.</p>
</div>
</div>
</div>


          </div>

      </div>

  
      <div class="clearer"></div>
    </div>




  </body>
</html>